package com.infore.statisticsAndAlarm.externalInterface;

import java.util.List;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;

import com.infore.statisticsAndAlarm.dto.OperationRealDataDto;
import com.infore.statisticsAndAlarm.select.dto.QueryParamDto;
import com.infore.statisticsAndAlarm.util.ResultEntity;

import io.swagger.annotations.ApiOperation;

@FeignClient(name="SiteManagement-Service", path="/SiteManagement-Service/")
public interface IStieMangementService {

	/**
	 * @Description: 通过因子编码取得因子信息  
	 * @param: @return      
	 * @return: ResultEntity
	 * @return map key:因子code value: Project    
	 * @throws
	 */
	@RequestMapping(value = "outSide/proiectInfoAlarm", method = RequestMethod.POST)
	@ResponseBody
	ResultEntity queryProjectByProjectCode();
	
	/**
	 * 
	 * @Description: 根据筛选条件得到站点编码
	 * @param provinceId 省份id
	 * @param basinnId 流域id
	 * @param stationClassifyId 站点类别id
	 * @param stationTypeId  站点分类id
	 * @param operCompanyId 运维公司id
	 * @param stationName 站点名称
	 * @param userId 用户id
	 * @param platfrom 平台
	 * @param appCode 系统编号
	 * @param admin 是否是管理员
	 * @return      
	 * @return: ResultEntity  Map 
	 * 	key :stationMn 站点mn
		key :areaName 区域名
		key :basinnName 流域名
		key :stationRiver 所属河流
		key :stationName 站点名  
	 * @throws
	 */
	@ApiOperation(value = "根据筛选条件得到站点编码")
    @ResponseBody
    @GetMapping(value = "outSide/queryStationMnByInfo")
    public ResultEntity queryStationMnByInfo(@RequestParam(value = "provinceId",required = false) String provinceId,
    		@RequestParam(value = "basinnId",required = false) String basinnId,
    		@RequestParam(value = "stationClassifyId",required = false) String stationClassifyId,
    		@RequestParam(value = "stationTypeId",required = false) String stationTypeId,
    		@RequestParam(value = "operCompanyId",required = false) String operCompanyId,
    		@RequestParam(value = "stationName",required = false) String stationName,
    		@RequestParam(value = "userId",required = false) String userId,
    		@RequestParam(value = "platfrom",required = false) String platfrom,
    		@RequestParam(value = "appCode",required = false) String appCode,
    		@RequestParam(value = "admin",required = false) String admin) ;
    
	/**
	 * 
	 * @Description: 通过单个站点编码取得因子编码 
	 * @param: @param stationMn 站点mn
	 * @param: @return      
	 * @return: ResultEntity  List<String> 站点下因子编码集合     
	 * @throws
	 */
	@ApiOperation(value = "通过单个站点编码取得因子编码")
	@ResponseBody
	@GetMapping(value = "statisAndAlarm/queryProjectByStationMn")
	public ResultEntity queryProjectByStationMn(@RequestParam(value = "stationMn",required = true) String stationMn);
	
	/**
	 * 
	 * @Description: 通过站点编码取得站点名称
	 * @param: @param stationMn 站点编码，可以传多个用，隔开
	 * @param: @return      
	 * @return: ResultEntity  List<Map<String, Object>> 返回大写key
	 * ARMLEVEL 目标等级
	 * MN 站点mn
	 * NAME 站点名
	 * basinn_name 流域名
	 * province_name  省份名
	 * @throws
	 */
	@ApiOperation(value = "通过站点编码取得站点名称")
	@ResponseBody
	@GetMapping(value = "statisAndAlarm/queryNameByStationMn")
	public ResultEntity queryNameByStationMn(@RequestParam(value = "stationMn",required = true) String stationMn);

	/**
	 * 
	 * @Description: 根据区域编码/流域返回站点部分信息
	 * @param queryCode 请求编码
	 * @param queryType 请求类型
	 * @param userId 用户id
	 * @param platform 平台
	 * @param appCode 系统编码
	 * @param admin 是否是管理员
	 * @return: ResultEntity  List<String> 站点id集合    
	 * @throws
	 */
	@ApiOperation(value = "根据区域编码/流域返回站点部分信息")
	@ResponseBody
	@GetMapping(value = "statisAndAlarm/queryStationInfoByCodes")
	public ResultEntity queryStationInfoByCodes(@RequestParam(value = "queryCode",required = true) String queryCode,
			@RequestParam(value = "queryType",required = true) String queryType,
			@RequestParam(value = "userId",required = false) String userId,
			@RequestParam(value = "platform",required = false) String platform,
			@RequestParam(value = "appCode",required = false) String appCode,
			@RequestParam(value = "admin",required = false) String admin);
	
	/**
	 * @Description: 根据区域编码/流域返回区域流域部分信息
	 * @param: @param queryCode 请求值
	 * @param: @param queryType 请求类型
	 * @return: ResultEntity    List<Area> 或者  List<Basinn> 区域集合或者流域集合 
	 * @throws
	 */
	@ApiOperation(value = "根据区域编码/流域返回站点部分信息")
	@ResponseBody
	@GetMapping(value = "statisAndAlarm/queryAreaByAreaCode")
	public ResultEntity queryAreaByAreaCode(@RequestParam(value = "queryCode",required = true) String queryCode,
			@RequestParam(value = "queryType",required = true) String queryType);

	/**
	 * @Description:根据mn拿到站点所有信息
	 * @param queryCode 站点mn可以传多个
	 * @return: ResultEntity   List<Station> 站点信息集合   
	 * @throws
	 */
	@ApiOperation(value = "根据mn拿到站点所有信息")
    @ResponseBody
    @GetMapping(value = "statisAndAlarm/queryAllInfoByMn")
    public ResultEntity queryAllInfoByMn(@RequestParam(value = "queryCode",required = true) String queryCode);
	
	/**
	 * @Description: 获取站点信息
	 * @param:queryParamDto 通用查询参数
	 * @param: @return      
	 * @return: ResultEntity      
	 * @throws
	 */
	@RequestMapping(value = "station/query", method = RequestMethod.POST)
	@ResponseBody
	ResultEntity queryStation(@RequestBody QueryParamDto queryParamDto);
	
	/**
	 * @Description: 通过站点mn获取因子集合 
	 * @param: @param mns 站点mn集合
	 * @param: @return      
	 * @return: ResultEntity  Map<String, Project>    
	 * @throws
	 */
    @ResponseBody
    @PostMapping(value = "statisAndAlarm/queryProjectByMn")
    ResultEntity queryProjectByMn(@RequestParam(value="mns",required=false) List<String> mns);
    
    @ResponseBody
    @GetMapping(value = "statisAndAlarm/queryInfoByMnSdcjgyy")
    ResultEntity queryInfoByMnSdcjgyy(@RequestParam(value="stationMns",required=false)String stationMns);
    
    @ResponseBody
    @PostMapping(value = "statisAndAlarm/operationRealData")
    ResultEntity operationRealData(OperationRealDataDto operationRealDataDto);
    
    @ResponseBody
    @PostMapping(value = "statisAndAlarm/operationRealDataType")
    ResultEntity operationRealDataType(OperationRealDataDto operationRealDataDto);
}
